{
 "cells": [
  {
   "cell_type": "markdown",
   "id": "341b2340",
   "metadata": {},
   "source": [
    "### 周边搜索"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "2b97aaf5",
   "metadata": {},
   "source": [
    "* 接口URL地址\n",
    "> https://restapi.amap.com/v3/place/text?parameters"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "7b3442ce",
   "metadata": {},
   "source": [
    "* 请求参数\n",
    "> 1. 按照关键词搜索\n",
    "> 2. 按照 查询POI类型（分类表-下载）"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "ecc12545",
   "metadata": {},
   "source": [
    "#### 1.关键词搜索"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "id": "a806d836",
   "metadata": {},
   "outputs": [],
   "source": [
    "# 地理编码/逆地理编码 API 是通过 HTTP/HTTPS 协议访问远程服务的接口，提供结构化地址与经纬度之间的相互转化的能力\n",
    "\n",
    "# 1. 调用requests模块（google chrome 浏览器）\n",
    "import requests\n",
    "# 2. 请求方法 ： GET\n",
    "# 3. URL地址 ： https://restapi.amap.com/v3/geocode/geo?parameters\n",
    "geo_url = \"https://restapi.amap.com/v3/geocode/geo?parameters\"\n",
    "# 4. 准备参数，用于交换数据 payload\n",
    "payload = {\n",
    "    \"key\":\"0b3cfe54629af240818df4563fad0ba8\",\n",
    "    \"address\":\"广东省广州市从化区广州南方学院\"\n",
    "}\n",
    "# 5. 发起请求\n",
    "r = requests.get(url=geo_url, params=payload)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 9,
   "id": "05116184",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<Response [200]>"
      ]
     },
     "execution_count": 9,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "r"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "id": "0a023f10",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "'113.678280,23.628439'"
      ]
     },
     "execution_count": 10,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "广州南方学院_location = r.json()['geocodes'][0]['location']\n",
    "广州南方学院_location"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "id": "efc1670a",
   "metadata": {},
   "outputs": [],
   "source": [
    "import requests "
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 14,
   "id": "2b051af2",
   "metadata": {},
   "outputs": [],
   "source": [
    "around_url = 'https://restapi.amap.com/v3/place/text?parameters'\n",
    "\n",
    "payload = {\n",
    "    'key':'0b3cfe54629af240818df4563fad0ba8',\n",
    "    'location':广州南方学院_location,\n",
    "    'keywords':'餐厅'\n",
    "}\n",
    "\n",
    "r = requests.get(around_url,params=payload)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 15,
   "id": "5532f582",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "{'suggestion': {'keywords': [], 'cities': []},\n",
       " 'count': '873',\n",
       " 'infocode': '10000',\n",
       " 'pois': [{'parent': [],\n",
       "   'address': '广州南方学院',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': '09:00-23:00',\n",
       "    'rating': '4.5',\n",
       "    'open_time': '09:00-23:00',\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;四川菜(川菜)',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/20080ba9f6fcd2808d64ce149b517ca9'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/9f40694ca108a175d36847d03ecf4ec0'},\n",
       "    {'title': [],\n",
       "     'url': 'https://img.alicdn.com/imgextra/i2/3695320962/O1CN01JFnmLv1IydhNhdLT4_!!3695320962-0-kbcontentapng.jpg'}],\n",
       "   'typecode': '050102',\n",
       "   'shopinfo': '1',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '重庆湖边纸包鱼',\n",
       "   'location': '113.680073,23.630511',\n",
       "   'tel': '13924024938',\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFL7NUA2'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇乌土村上围2队13号',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': [],\n",
       "    'rating': [],\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '壹休盖饭',\n",
       "   'location': '113.679611,23.630517',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0HRHG0RSP'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇中山大学南方学院南门',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': [],\n",
       "    'rating': '3.8',\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;外国餐厅;韩国料理',\n",
       "   'photos': [],\n",
       "   'typecode': '050203',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '炸鸡队长(韩式炸鸡店)',\n",
       "   'location': '113.676603,23.630170',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFHVMT24'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇中大南方',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': [],\n",
       "    'rating': [],\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;休闲餐饮场所;休闲餐饮场所',\n",
       "   'photos': [],\n",
       "   'typecode': '050400',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '初心休闲小屋',\n",
       "   'location': '113.676568,23.631259',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0HAFBTLWE'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇广州南方学院后门润泰超市1层05号商铺',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': [],\n",
       "    'rating': [],\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '东记乡村美食',\n",
       "   'location': '113.679283,23.632572',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0G3APADKJ'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇牌坊东路45号',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': '56.00',\n",
       "    'opentime2': [],\n",
       "    'rating': '4.4',\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/098f3972854783f4a0931f73645de6db'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/89a15022589f24ae17885d3374f31a84'}],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '天天酒家特色农家菜',\n",
       "   'location': '113.657777,23.640442',\n",
       "   'tel': '020-87838296;13533067893',\n",
       "   'shopid': [],\n",
       "   'id': 'B00140LJS7'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉区广州南方学院',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': [],\n",
       "    'rating': [],\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;外国餐厅;西餐厅(综合风味)',\n",
       "   'photos': [],\n",
       "   'typecode': '050201',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': 'Uni-hotel西餐',\n",
       "   'location': '113.679222,23.632671',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0GR3OMDZ2'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇温泉东路99号',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': '53.00',\n",
       "    'opentime2': '10:00-21:00',\n",
       "    'rating': '4.6',\n",
       "    'open_time': '10:00-21:00',\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/18132bec7fd836ec909aae4ad8d92e5f'},\n",
       "    {'title': '产品图',\n",
       "     'url': 'http://store.is.autonavi.com/showpic/9d00e60d9421930c973d23c0ce6fd0fb'},\n",
       "    {'title': '产品图',\n",
       "     'url': 'http://store.is.autonavi.com/showpic/c12a7ff8105dd732137d63da821b6a5e'}],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '幸福楼酒店(温泉东路)',\n",
       "   'location': '113.654186,23.644836',\n",
       "   'tel': '020-87838813;020-87838758',\n",
       "   'shopid': [],\n",
       "   'id': 'B00140FG8A'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇碧泉路8号',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': '74.00',\n",
       "    'opentime2': [],\n",
       "    'rating': '4.2',\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/c6c4adb45d8da4215bb15b03f1b814a6'}],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '碧溪农家菜',\n",
       "   'location': '113.654796,23.644038',\n",
       "   'tel': '020-87838381;13527756813',\n",
       "   'shopid': [],\n",
       "   'id': 'B00140H71J'},\n",
       "  {'parent': [],\n",
       "   'address': '东埔附近',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': [],\n",
       "    'rating': '4.3',\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '温泉东埔农庄',\n",
       "   'location': '113.662092,23.659556',\n",
       "   'tel': '13602211368;13902323168',\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFF5KYEU'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇龙岗村延庆里10号',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': '10:00-20:00',\n",
       "    'rating': '3.6',\n",
       "    'open_time': '10:00-20:00',\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;广东菜(粤菜)',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/488b38e7d12a144375129ee602523c88'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/80f404bf446ee2e83bb77c29157fa824'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/b2b8ccd876a1fe963da5f10b13c7d50e'}],\n",
       "   'typecode': '050103',\n",
       "   'shopinfo': '1',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '四季农庄',\n",
       "   'location': '113.664197,23.597786',\n",
       "   'tel': '13434279298',\n",
       "   'shopid': [],\n",
       "   'id': 'B0IAMAHNK3'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇温泉东路62号碧泉一横街二巷',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': '09:30-21:30',\n",
       "    'rating': '4.1',\n",
       "    'open_time': '09:30-21:30',\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;广东菜(粤菜)',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/de46d11cc1c2d594328e981e47c30465'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/b3b9e19f80b52a27b9ef6717e2726d17'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/de240fa82a66bbc41319854ca9d8b9d9'}],\n",
       "   'typecode': '050103',\n",
       "   'shopinfo': '1',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '乡约私房菜馆',\n",
       "   'location': '113.654213,23.644589',\n",
       "   'tel': '15918498423',\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFLBF6O0'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇温泉东路97号毅华温泉酒店2层',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': '68.00',\n",
       "    'opentime2': [],\n",
       "    'rating': '3.9',\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/34ac1a59b88c3b41ca8b59e650fce734'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/2b95c34e6d0df8893c6bdc2bd77270fa'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/115879d576c7b6de8ffd6bc31b2ab8b1'}],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '毅华轩酒家(温泉镇店)',\n",
       "   'location': '113.653770,23.644272',\n",
       "   'tel': '020-62163888',\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFF4BZI3'},\n",
       "  {'parent': 'B00141ICQP',\n",
       "   'address': '温泉镇温泉西路21号财富度假酒店',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': '42.00',\n",
       "    'opentime2': [],\n",
       "    'rating': '4.1',\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': '312',\n",
       "   'adname': '从化区',\n",
       "   'name': '财富度假酒店中餐厅(温泉西路店)',\n",
       "   'location': '113.643299,23.638148',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFKQOQJS'},\n",
       "  {'parent': [],\n",
       "   'address': '广卅市温镇天湖路9号之二首层,二层',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': '10:30-01:00',\n",
       "    'rating': '4.0',\n",
       "    'open_time': '10:30-01:00',\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;广东菜(粤菜)',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/8ff8d52ed9fc591f978710ffe7880c97'}],\n",
       "   'typecode': '050103',\n",
       "   'shopinfo': '1',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '农家私厨',\n",
       "   'location': '113.644567,23.638855',\n",
       "   'tel': '13926487938',\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFMBHDOL'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇石坑村东儒队00762号',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': [],\n",
       "    'rating': [],\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;外国餐厅;外国餐厅',\n",
       "   'photos': [],\n",
       "   'typecode': '050200',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '米斯特比萨',\n",
       "   'location': '113.698059,23.611033',\n",
       "   'tel': '13533792521',\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFKT17JQ'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇温泉乌土村随便公寓',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': [],\n",
       "    'rating': [],\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;外国餐厅;韩国料理',\n",
       "   'photos': [],\n",
       "   'typecode': '050203',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '鸡啤咯哒(中大店)',\n",
       "   'location': '113.680035,23.631318',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0HROCMJ59'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉明月山溪广场及第大街18-20档',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': '08:00-14:30；17:00-21:30',\n",
       "    'rating': '4.2',\n",
       "    'open_time': '08:00-14:30 17:00-21:30',\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;广东菜(粤菜)',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/6924b6c0041a860033ce25b0a17efed0'}],\n",
       "   'typecode': '050103',\n",
       "   'shopinfo': '1',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '枢哥私厨农庄',\n",
       "   'location': '113.636524,23.626752',\n",
       "   'tel': '020-37977660;13711095933',\n",
       "   'shopid': [],\n",
       "   'id': 'B0G3K5OP8U'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇广州南方学院后门润泰超市1层05号商铺',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': [],\n",
       "    'rating': [],\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;外国餐厅;外国餐厅',\n",
       "   'photos': [],\n",
       "   'typecode': '050200',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '铁板烧',\n",
       "   'location': '113.679405,23.632673',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0H6ZUSDBT'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉东路113号',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'star': [],\n",
       "    'opentime2': [],\n",
       "    'rating': '4.5',\n",
       "    'lowest_price': [],\n",
       "    'hotel_ordering': [],\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅|住宿服务;宾馆酒店;宾馆酒店',\n",
       "   'photos': [{'provider': [],\n",
       "     'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/0d16418bc6bca5cfe11506d2748cd3a9'},\n",
       "    {'provider': [],\n",
       "     'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/892924547d6fc4415dbbb474f9138613'}],\n",
       "   'typecode': '050100|100100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '怡东楼宾馆',\n",
       "   'location': '113.653053,23.653028',\n",
       "   'tel': '020-87839122;020-87839146',\n",
       "   'shopid': [],\n",
       "   'id': 'B0G0O5VQRS'}],\n",
       " 'status': '1',\n",
       " 'info': 'OK'}"
      ]
     },
     "execution_count": 15,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "r.json()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 35,
   "id": "2320dcdf",
   "metadata": {},
   "outputs": [],
   "source": [
    "around_url = 'https://restapi.amap.com/v3/place/text?parameters'\n",
    "\n",
    "payload = {\n",
    "    'key':'0b3cfe54629af240818df4563fad0ba8',\n",
    "    'location':广州南方学院_location,\n",
    "    'types':'050100',\n",
    "    'page':'1'\n",
    "}\n",
    "\n",
    "r = requests.get(around_url,params=payload)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 36,
   "id": "bf24c8c8",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "{'suggestion': {'keywords': [], 'cities': []},\n",
       " 'count': '878',\n",
       " 'infocode': '10000',\n",
       " 'pois': [{'parent': [],\n",
       "   'address': '广州南方学院',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': '09:00-23:00',\n",
       "    'rating': '4.5',\n",
       "    'open_time': '09:00-23:00',\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;四川菜(川菜)',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/20080ba9f6fcd2808d64ce149b517ca9'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/9f40694ca108a175d36847d03ecf4ec0'},\n",
       "    {'title': [],\n",
       "     'url': 'https://img.alicdn.com/imgextra/i2/3695320962/O1CN01JFnmLv1IydhNhdLT4_!!3695320962-0-kbcontentapng.jpg'}],\n",
       "   'typecode': '050102',\n",
       "   'shopinfo': '1',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '重庆湖边纸包鱼',\n",
       "   'location': '113.680073,23.630511',\n",
       "   'tel': '13924024938',\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFL7NUA2'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇温泉东路62号碧泉一横街二巷',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': '09:30-21:30',\n",
       "    'rating': '4.1',\n",
       "    'open_time': '09:30-21:30',\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;广东菜(粤菜)',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/de46d11cc1c2d594328e981e47c30465'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/b3b9e19f80b52a27b9ef6717e2726d17'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/de240fa82a66bbc41319854ca9d8b9d9'}],\n",
       "   'typecode': '050103',\n",
       "   'shopinfo': '1',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '乡约私房菜馆',\n",
       "   'location': '113.654213,23.644589',\n",
       "   'tel': '15918498423',\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFLBF6O0'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇乌土村上围2队13号',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': [],\n",
       "    'rating': [],\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '壹休盖饭',\n",
       "   'location': '113.679611,23.630517',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0HRHG0RSP'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇,碧泉一横街23号',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': '37.00',\n",
       "    'opentime2': '10:00-01:45',\n",
       "    'rating': '4.2',\n",
       "    'open_time': '10:00-01:45',\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;广东菜(粤菜)',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/74d3adb93d9e3b8f5ffd05badd2d24eb'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/f160673b4058f79a1014e62f8c32166e'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/99f09d0032f41bcfb1da2f1cccc15d0c'}],\n",
       "   'typecode': '050103',\n",
       "   'shopinfo': '1',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '潮汕砂锅粥',\n",
       "   'location': '113.655492,23.645358',\n",
       "   'tel': '18588812880',\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFJ5J0XA'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇广州南方学院后门润泰超市1层05号商铺',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': [],\n",
       "    'rating': [],\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '湘味小厨',\n",
       "   'location': '113.679283,23.632572',\n",
       "   'tel': '13005184390',\n",
       "   'shopid': [],\n",
       "   'id': 'B0GKHC2KQN'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇广州南方学院后门润泰超市1层05号商铺',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': [],\n",
       "    'rating': [],\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '东记乡村美食',\n",
       "   'location': '113.679283,23.632572',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0G3APADKJ'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇广州南方学院后门润泰超市1层05号商铺',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': [],\n",
       "    'rating': [],\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '老地方乐山油炸串串',\n",
       "   'location': '113.679405,23.632673',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0H6Y1AW1Y'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇广州南方学院明辩路2号',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': [],\n",
       "    'rating': [],\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '耀记美食',\n",
       "   'location': '113.679405,23.632673',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0GRGOTLSL'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇温泉东路80号',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': '70.00',\n",
       "    'opentime2': '08:00-23:00',\n",
       "    'rating': '4.2',\n",
       "    'open_time': '08:00-23:00',\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/53861669aef0902a48a70997e12df78f'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/1f702dcfbc12b70a78a5b3ab9319c130'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/1fc5e19b419e66df73ecc8fe2e3b7d97'}],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '陶然餐厅',\n",
       "   'location': '113.652237,23.649106',\n",
       "   'tel': '020-87830888;020-87838844',\n",
       "   'shopid': [],\n",
       "   'id': 'B00140AB59'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇牌坊东路45号',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': '56.00',\n",
       "    'opentime2': [],\n",
       "    'rating': '4.4',\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/098f3972854783f4a0931f73645de6db'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/89a15022589f24ae17885d3374f31a84'}],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '天天酒家特色农家菜',\n",
       "   'location': '113.657777,23.640442',\n",
       "   'tel': '020-87838296;13533067893',\n",
       "   'shopid': [],\n",
       "   'id': 'B00140LJS7'},\n",
       "  {'parent': [],\n",
       "   'address': '龙宣街与宣星四街交叉口东南约20米',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': [],\n",
       "    'rating': '4.0',\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/1e480633cc8067a17bc5f37bfe0646cb'}],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '1',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '运动谷农庄',\n",
       "   'location': '113.643690,23.599463',\n",
       "   'tel': '13711092819',\n",
       "   'shopid': [],\n",
       "   'id': 'B00141RT7I'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇御泉大道691号',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': '每天10:00-21:00',\n",
       "    'rating': '4.3',\n",
       "    'open_time': '10:00-21:00',\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/16ef1ab8a71897357cfa6c455b4db9d2'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/e23c0dde3dbf8035a834af6f939ff014'}],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '1',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '聚福缘农庄',\n",
       "   'location': '113.679939,23.659544',\n",
       "   'tel': '13902382128',\n",
       "   'shopid': [],\n",
       "   'id': 'B0HA4HSJUX'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇温泉东路99号',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': '53.00',\n",
       "    'opentime2': '10:00-21:00',\n",
       "    'rating': '4.7',\n",
       "    'open_time': '10:00-21:00',\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/18132bec7fd836ec909aae4ad8d92e5f'},\n",
       "    {'title': '产品图',\n",
       "     'url': 'http://store.is.autonavi.com/showpic/9d00e60d9421930c973d23c0ce6fd0fb'},\n",
       "    {'title': '产品图',\n",
       "     'url': 'http://store.is.autonavi.com/showpic/c12a7ff8105dd732137d63da821b6a5e'}],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '幸福楼酒店(温泉东路)',\n",
       "   'location': '113.654186,23.644836',\n",
       "   'tel': '020-87838813;020-87838758',\n",
       "   'shopid': [],\n",
       "   'id': 'B00140FG8A'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉大道与冲口路交叉路口往东北约90米',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': [],\n",
       "    'rating': [],\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;广东菜(粤菜)',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/bb8acdac9f42acb9ee6b75e3dc880fd6'}],\n",
       "   'typecode': '050103',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '温泉餐厅',\n",
       "   'location': '113.650397,23.625886',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0G064M5QE'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇温泉东路97号毅华温泉酒店2层',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': '68.00',\n",
       "    'opentime2': [],\n",
       "    'rating': '3.9',\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/34ac1a59b88c3b41ca8b59e650fce734'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/2b95c34e6d0df8893c6bdc2bd77270fa'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/115879d576c7b6de8ffd6bc31b2ab8b1'}],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '毅华轩酒家(温泉镇店)',\n",
       "   'location': '113.653770,23.644272',\n",
       "   'tel': '020-62163888',\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFF4BZI3'},\n",
       "  {'parent': [],\n",
       "   'address': '东埔附近',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': [],\n",
       "    'rating': '4.4',\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '温泉东埔农庄',\n",
       "   'location': '113.662092,23.659556',\n",
       "   'tel': '13602211368;13902323168',\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFF5KYEU'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉镇温泉大道988号',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': '74.00',\n",
       "    'opentime2': '周一至周日:10:00-21:00',\n",
       "    'rating': '4.7',\n",
       "    'open_time': '10:00-21:00',\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/72c1eb3ecb88d06103288046d00baf85'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/bbf1ac15c5b494c6ccc1e6cbd53cc323'},\n",
       "    {'title': [],\n",
       "     'url': 'https://img.alicdn.com/imgextra/i1/3695320962/O1CN011IydfrHXZtogugg_!!3695320962-0-kbcontentapng.jpg'}],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '同心农庄(温泉大道店)',\n",
       "   'location': '113.678614,23.662933',\n",
       "   'tel': '13434353603',\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFL1FKLX'},\n",
       "  {'parent': [],\n",
       "   'address': '石坑村广场139号',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': '10:00-21:00',\n",
       "    'rating': '4.3',\n",
       "    'open_time': '10:00-21:00',\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/61613e27db9667ebc695606ee8d01d4a'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/9fdd9160f7b925a298109999e1ed5134'},\n",
       "    {'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/5af4a575f15bb0a7a5e487bc1606bc8c'}],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '1',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '广场饭店',\n",
       "   'location': '113.714796,23.579464',\n",
       "   'tel': '13924112229',\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFLARAHQ'},\n",
       "  {'parent': 'B00141ICQP',\n",
       "   'address': '温泉镇温泉西路21号财富度假酒店',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': '42.00',\n",
       "    'opentime2': [],\n",
       "    'rating': '4.1',\n",
       "    'open_time': [],\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': '312',\n",
       "   'adname': '从化区',\n",
       "   'name': '财富度假酒店中餐厅(温泉西路店)',\n",
       "   'location': '113.643299,23.638148',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFKQOQJS'},\n",
       "  {'parent': [],\n",
       "   'address': '温泉西路9号',\n",
       "   'distance': [],\n",
       "   'pname': '广东省',\n",
       "   'importance': [],\n",
       "   'biz_ext': {'cost': [],\n",
       "    'opentime2': '19:00-23:30',\n",
       "    'rating': '3.8',\n",
       "    'open_time': '19:00-23:30',\n",
       "    'meal_ordering': '0'},\n",
       "   'biz_type': 'diner',\n",
       "   'cityname': '广州市',\n",
       "   'type': '餐饮服务;中餐厅;中餐厅',\n",
       "   'photos': [{'title': [],\n",
       "     'url': 'http://store.is.autonavi.com/showpic/c940439aba82384d3948e184ca9dcbe6'}],\n",
       "   'typecode': '050100',\n",
       "   'shopinfo': '0',\n",
       "   'poiweight': [],\n",
       "   'childtype': [],\n",
       "   'adname': '从化区',\n",
       "   'name': '啤酒屋',\n",
       "   'location': '113.642473,23.630834',\n",
       "   'tel': [],\n",
       "   'shopid': [],\n",
       "   'id': 'B0FFKFHZ1U'}],\n",
       " 'status': '1',\n",
       " 'info': 'OK'}"
      ]
     },
     "execution_count": 36,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "r.json()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 17,
   "id": "11770610",
   "metadata": {},
   "outputs": [],
   "source": [
    "import pandas as pd"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 32,
   "id": "61080b1a",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>count</th>\n",
       "      <th>infocode</th>\n",
       "      <th>pois</th>\n",
       "      <th>status</th>\n",
       "      <th>info</th>\n",
       "      <th>suggestion.keywords</th>\n",
       "      <th>suggestion.cities</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>0</td>\n",
       "      <td>10000</td>\n",
       "      <td>[]</td>\n",
       "      <td>1</td>\n",
       "      <td>OK</td>\n",
       "      <td>[]</td>\n",
       "      <td>[]</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "  count infocode pois status info suggestion.keywords suggestion.cities\n",
       "0     0    10000   []      1   OK                  []                []"
      ]
     },
     "execution_count": 32,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "pd.json_normalize(r.json())"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "57691a33",
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3 (ipykernel)",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.9.7"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
